home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Tools 2
/
Amiga Tools 2.iso
/
tex
/
macros
/
source
/
contrib
/
supported
/
xypic
/
src
/
xybtip10.mf
< prev
next >
Wrap
Text File
|
1995-03-15
|
3KB
|
81 lines
% $Id: xybtip10.mf,v 2.7 1992/12/14 01:41:26 kris Exp $
%
% XYBTIP10: lower arrow tips for XY-pic at 10 point "technical style".
% Copyright (c) 1991,1992 Kristoffer H. Rose <kris@diku.dk>
%
% This file is part of the XY-pic macro package.
%
% The XY-pic macro package is free software; you can redistribute it and/or
% modify it under the terms of the GNU General Public License as published by
% the Free Software Foundation; either version 2 of the License, or (at your
% option) any later version.
%
% The XY-pic macro package is distributed in the hope that it will be
% useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
% Public License for more details.
%
% You should have received a copy of the GNU General Public License along
% with this macro package; if not, write to the Free Software Foundation,
% Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
% _________________________________________________________________________
%
% CONTENTS: Arrow tips *pointing* in all directions. With zero bounding box
% placed at the tip; note most of the ink goes on the opposite side of where
% the tip points.
%
% This font contains the half of the tip that is lower when pointing right.
% _________________________________________________________________________
%
font_identifier "XYBTIP"; font_size 10pt#;
mode_setup;
% METANESS...
%
segl# = 1/2 designsize; define_pixels(segl); % segment length
segx# = 0.62 segl#; define_pixels(segx); % segment height
segw# = .4pt#; define_whole_blacker_pixels(segw); % segment thickness
%
tipo# = 0#; define_pixels(tipo); % tip overshoot
curvature = 1/3; % 1 = straight tails, 0= curved tails
%
pickup pencircle scaled segw; char_pen := savepen;
%
% chartowards makes char cc a tip pointing towards (dx,dy)...
%
def chartowards(expr cc,dx,dy) =
beginchar(cc,0,0,0);
a := angle(dx,dy);
z0 = (tipo,0) rotated a; % tip of tip
z1 = (-segl,0) rotated a; % center of tail
z2 = (-segl,-1/2 segx) rotated a; % tail ends
z3 = curvature [z1,z2] ; % tail directions
pickup char_pen; draw z2..{-z3}z0;
penlabels(0,1,2,3);
endchar
enddef;
% TESTING...we redefine openit because the characters extend far to the
% left of the bounding box!
%
def openit = openwindow currentwindow
from origin to (screen_cols,screen_rows) at (-200,300) enddef;
% GENERATE...
%
input xyd
bye.
%
% $Log: xybtip10.mf,v $
% Revision 2.7 1992/12/14 01:41:26 kris
% Now uses xyd.mf.
%
% Revision 2.1 1992/01/02 14:54:07 kris
% Release version.
%
% Revision 1.1 1991/11/27 06:41:03 kris
% Initial: \beta-test on DIKU.
%
% Based on obsolete xytip10.mf v.1.4.